package com.platform.demo.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.platform.demo.dao.UserDao;
import com.platform.demo.entity.User;
import com.platform.demo.service.UserService;

@Service
@Transactional
public class UserServiceImpl implements UserService {

	@Autowired
	private UserDao userDao;

	/**
	 * @see com.platform.demo.service.itcast.service.UserService#queryById(long)
	 * @param id
	 * @return
	 */
	public User queryById(long id) {
		return userDao.queryById(id);
	}

	/**
	 * @see com.platform.demo.service.itcast.service.UserService#queryAll()
	 * @return
	 */
	public List<User> queryAll() {
		return userDao.queryAll();
	}

}
